package com.ybwh.springboot1.model.po;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;
import javax.persistence.UniqueConstraint;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import lombok.Data;

/**
*
*/
@Data
@Entity 
@Table(name = "t_dict", uniqueConstraints = { @UniqueConstraint(columnNames = { "id" }) })
public class Dict {

	/**
	*主键
	*/
	@Id
	@SequenceGenerator(name = "t_dict")
	@Column(name = "id")
	private Long id;
	
	/**
	*组名称
	*/
	@Column(name = "dict_group")
	private String dictGroup;
	
	/**
	*描述
	*/
	@Column(name = "dict_descr")
	private String dictDescr;
	
	/**
	*单项key
	*/
	@Column(name = "dict_item_key")
	private String dictItemKey;
	
	/**
	*单项value
	*/
	@Column(name = "dict_item_value")
	private String dictItemValue;
	
	/**
	*是否已删除，1-是，0-否
	*/
	@Column(name = "is_del")
	private Integer isDel;
	
	/**
	*创建时间
	*/
	@Column(name = "create_ts")
	private Date createTs;
	
	/**
	*最后更新时间
	*/
	@Column(name = "update_ts")
	private Date updateTs;
	
	/**
	*创建人ID
	*/
	@Column(name = "create_id")
	private Long createId;
	
	/**
	*最后更新人ID
	*/
	@Column(name = "update_id")
	private Long updateId;
	

	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this, ToStringStyle.JSON_STYLE);
	}
	
}